/*
 * @Author: doing
 * @Date: 2023-08-22 10:55:55
 * @LastEditors: git config user.name && git config user.email
 * @LastEditTime: 2023-08-31 17:30:08
 * @FilePath: \background-management-system\src\api\video.js
 * @Description: 
 * 视频接口管理
 * Copyright (c) 2023 by 1540265624@qq.com, All Rights Reserved. 
 */
import axios from '~/axios.js'

//视频列表
export function getVideoList(body){
    return axios.post('/content/video/search',body)
}

//新增视频
export function addVideoList(body){
    return axios.post('/content/video/addVideo',body)
}

//修改视频信息
export function updataVideoList(body){
    return axios.put('/content/video',body)
}

//删除视频
export function deleteVideo(id){
    return axios.delete(`/content/video/deleteVideoById/${id}`)
}


//上传视频接口（formData对象）
export function uploadVideo(body){
    //接口好了之后替换第一条
    return axios.post('/content/video/upload',body)
}
//新增视频接口
export function getVideoUrl(videoSourceId){
    return axios.get(`/content/video/getPlayUrl/${videoSourceId}`)
}

//删除阿里云视频接口
export function deleteVideoList(videoId){
    return axios.delete(`/content/video/deleteVideoBySourceId/${videoId}`)
}


